﻿-----------------------------------------------------------------------------------------------------------------------------------
      name:  Credibility
       log:  E:\log.log
  log type:  text
 opened on:  11 May 2019, 10:35:56

. 
. *     ***************************************************************** *
. *     ***************************************************************** *
. *     File-Name:  Leadership Credibility                                *
. *     Date:       May  2019                                             *
. *     Author:     Eddie Hearn                                           *
. *     Purpose:    Replication File                                      *
. *     Input File: data.dta                                              *
. *     Output File: log.log                                              *
. *     Data Output: None                                                 *
. *     Program:      Stata 14                                            *
. *     Machine:    (HP)Office                                            *
. *     ****************************************************************  *
. *     ****************************************************************  *
. 
. use "E:\data.dta"

. ssc inst tab_chi
checking tab_chi consistency and verifying not already installed...
all files already exist and are up to date.

. 
. *     ****************************************************************  *
. *                     Results - Table 1                                 *
. *     ****************************************************************  *
. 
. 
. 
. tab control

    control |      Freq.     Percent        Cum.
------------+-----------------------------------
          1 |        187       55.82       55.82
          2 |        106       31.64       87.46
          3 |         42       12.54      100.00
------------+-----------------------------------
      Total |        335      100.00

. tab Trump

      Trump |      Freq.     Percent        Cum.
------------+-----------------------------------
          1 |        159       47.89       47.89
          2 |        102       30.72       78.61
          3 |         71       21.39      100.00
------------+-----------------------------------
      Total |        332      100.00

. tab US

         US |      Freq.     Percent        Cum.
------------+-----------------------------------
          1 |        161       48.35       48.35
          2 |        122       36.64       84.98
          3 |         50       15.02      100.00
------------+-----------------------------------
      Total |        333      100.00

. 
. *     ****************************************************************  *
. *                     Hypothesis 1 - Table 2                            *
. *     ****************************************************************  *
. 
. 
. tab Trump

      Trump |      Freq.     Percent        Cum.
------------+-----------------------------------
          1 |        159       47.89       47.89
          2 |        102       30.72       78.61
          3 |         71       21.39      100.00
------------+-----------------------------------
      Total |        332      100.00

. tab control

    control |      Freq.     Percent        Cum.
------------+-----------------------------------
          1 |        187       55.82       55.82
          2 |        106       31.64       87.46
          3 |         42       12.54      100.00
------------+-----------------------------------
      Total |        335      100.00

. 
. tabi 187 106 42 \\ 159 102 71, chi V

           |               col
       row |         1          2          3 |     Total
-----------+---------------------------------+----------
         1 |       187        106         42 |       335 
         2 |       159        102         71 |       332 
-----------+---------------------------------+----------
     Total |       346        208        113 |       667 

          Pearson chi2(2) =   9.7720   Pr = 0.008
               Cramér's V =   0.1210

. 
. tabchii 187 106 42 \ 159 102 71, a

          observed frequency
          expected frequency
          adjusted residual

-------------------------------------
          |            col           
      row |       1        2        3
----------+--------------------------
        1 |     187      106       42
          | 173.778  104.468   56.754
          |   2.049    0.256   -3.046
          | 
        2 |     159      102       71
          | 172.222  103.532   56.246
          |  -2.049   -0.256    3.046
-------------------------------------

         Pearson chi2(2) =   9.7720   Pr = 0.008
likelihood-ratio chi2(2) =   9.8582   Pr = 0.007

. 
. *     ****************************************************************  *
. *                     Hypothesis 2 - Table 3                            *
. *     ****************************************************************  *
. 
. tab US

         US |      Freq.     Percent        Cum.
------------+-----------------------------------
          1 |        161       48.35       48.35
          2 |        122       36.64       84.98
          3 |         50       15.02      100.00
------------+-----------------------------------
      Total |        333      100.00

. tab control

    control |      Freq.     Percent        Cum.
------------+-----------------------------------
          1 |        187       55.82       55.82
          2 |        106       31.64       87.46
          3 |         42       12.54      100.00
------------+-----------------------------------
      Total |        335      100.00

. 
. tabi 187 106 42 \\  161 122 50, chi V

           |               col
       row |         1          2          3 |     Total
-----------+---------------------------------+----------
         1 |       187        106         42 |       335 
         2 |       161        122         50 |       333 
-----------+---------------------------------+----------
     Total |       348        228         92 |       668 

          Pearson chi2(2) =   3.7550   Pr = 0.153
               Cramér's V =   0.0750

. tabchii 187 106 42 \  161 122 50, a

          observed frequency
          expected frequency
          adjusted residual

-------------------------------------
          |            col           
      row |       1        2        3
----------+--------------------------
        1 |     187      106       42
          | 174.521  114.341   46.138
          |   1.933   -1.361   -0.929
          | 
        2 |     161      122       50
          | 173.479  113.659   45.862
          |  -1.933    1.361    0.929
-------------------------------------

         Pearson chi2(2) =   3.7550   Pr = 0.153
likelihood-ratio chi2(2) =   3.7586   Pr = 0.153

. 
. *     ****************************************************************  *
. *                     Hypothesis 3 - Table 4                            *
. *     ****************************************************************  *
. 
. tab US

         US |      Freq.     Percent        Cum.
------------+-----------------------------------
          1 |        161       48.35       48.35
          2 |        122       36.64       84.98
          3 |         50       15.02      100.00
------------+-----------------------------------
      Total |        333      100.00

. tab Trump

      Trump |      Freq.     Percent        Cum.
------------+-----------------------------------
          1 |        159       47.89       47.89
          2 |        102       30.72       78.61
          3 |         71       21.39      100.00
------------+-----------------------------------
      Total |        332      100.00

. 
. tabi 161 122 50 \\ 159 102 71, chi V

           |               col
       row |         1          2          3 |     Total
-----------+---------------------------------+----------
         1 |       161        122         50 |       333 
         2 |       159        102         71 |       332 
-----------+---------------------------------+----------
     Total |       320        224        121 |       665 

          Pearson chi2(2) =   5.4414   Pr = 0.066
               Cramér's V =   0.0905

. tabchii 161 122 50 \ 159 102 71, a

          observed frequency
          expected frequency
          adjusted residual

-------------------------------------
          |            col           
      row |       1        2        3
----------+--------------------------
        1 |     161      122       50
          | 160.241  112.168   60.591
          |   0.118    1.613   -2.129
          | 
        2 |     159      102       71
          | 159.759  111.832   60.409
          |  -0.118   -1.613    2.129
-------------------------------------

         Pearson chi2(2) =   5.4414   Pr = 0.066
likelihood-ratio chi2(2) =   5.4622   Pr = 0.065

. 
. *     ****************************************************************  *
. *                     Sample Charachteristics - Table A1                *
. *     ****************************************************************  *
. 
. gen female = Gender-1

. 
. gen collgrad = 1 if Educ>8
(581 missing values generated)

. recode collgrad (.=0)
(collgrad: 581 changes made)

. 
. tab age

        age |      Freq.     Percent        Cum.
------------+-----------------------------------
          1 |         85        8.50        8.50
          2 |         88        8.80       17.30
          3 |         72        7.20       24.50
          4 |        103       10.30       34.80
          5 |         76        7.60       42.40
          6 |         73        7.30       49.70
          7 |         91        9.10       58.80
          8 |         89        8.90       67.70
          9 |         82        8.20       75.90
         10 |        241       24.10      100.00
------------+-----------------------------------
      Total |      1,000      100.00

. tab female

     female |      Freq.     Percent        Cum.
------------+-----------------------------------
          0 |        483       48.30       48.30
          1 |        517       51.70      100.00
------------+-----------------------------------
      Total |      1,000      100.00

. tab collgrad

   collgrad |      Freq.     Percent        Cum.
------------+-----------------------------------
          0 |        581       58.10       58.10
          1 |        419       41.90      100.00
------------+-----------------------------------
      Total |      1,000      100.00

. 
. 
. *     ****************************************************************  *
. *                   Attitude Strength                                   *
. *     ****************************************************************  *
. 
. 
. tab control

    control |      Freq.     Percent        Cum.
------------+-----------------------------------
          1 |        187       55.82       55.82
          2 |        106       31.64       87.46
          3 |         42       12.54      100.00
------------+-----------------------------------
      Total |        335      100.00

. tab Trade

      Trade |      Freq.     Percent        Cum.
------------+-----------------------------------
          1 |        646       64.60       64.60
          2 |        156       15.60       80.20
          3 |        198       19.80      100.00
------------+-----------------------------------
      Total |      1,000      100.00

. 
. *     ****************************************************************  *
. *                    Reduced Sample  Hypothesis 1 - Table C1            *
. *     ****************************************************************  *
. 
. 
. tab Trump if respid < 1105

      Trump |      Freq.     Percent        Cum.
------------+-----------------------------------
          1 |        157       48.01       48.01
          2 |        100       30.58       78.59
          3 |         70       21.41      100.00
------------+-----------------------------------
      Total |        327      100.00

. tab control if respid < 1105

    control |      Freq.     Percent        Cum.
------------+-----------------------------------
          1 |        183       55.45       55.45
          2 |        105       31.82       87.27
          3 |         42       12.73      100.00
------------+-----------------------------------
      Total |        330      100.00

. 
. tabi 183 105 42  \\ 157 100 70, chi V 

           |               col
       row |         1          2          3 |     Total
-----------+---------------------------------+----------
         1 |       183        105         42 |       330 
         2 |       157        100         70 |       327 
-----------+---------------------------------+----------
     Total |       340        205        112 |       657 

          Pearson chi2(2) =   9.0967   Pr = 0.011
               Cramér's V =   0.1177

. tabchii 183 105 42  \ 157 100 70, a

          observed frequency
          expected frequency
          adjusted residual

-------------------------------------
          |            col           
      row |       1        2        3
----------+--------------------------
        1 |     183      105       42
          | 170.776  102.968   56.256
          |   1.909    0.342   -2.958
          | 
        2 |     157      100       70
          | 169.224  102.032   55.744
          |  -1.909   -0.342    2.958
-------------------------------------

         Pearson chi2(2) =   9.0967   Pr = 0.011
likelihood-ratio chi2(2) =   9.1732   Pr = 0.010

. 
. 
. *     ****************************************************************  *
. *                    Reduced Sample  Hypothesis 2 - Table C2            *
. *     ****************************************************************  *
. 
. 
. tab US if respid < 1105

         US |      Freq.     Percent        Cum.
------------+-----------------------------------
          1 |        158       48.17       48.17
          2 |        121       36.89       85.06
          3 |         49       14.94      100.00
------------+-----------------------------------
      Total |        328      100.00

. tab control if respid < 1105

    control |      Freq.     Percent        Cum.
------------+-----------------------------------
          1 |        183       55.45       55.45
          2 |        105       31.82       87.27
          3 |         42       12.73      100.00
------------+-----------------------------------
      Total |        330      100.00

. 
. tabi 183 105 42  \\ 158 121 49, chi V

           |               col
       row |         1          2          3 |     Total
-----------+---------------------------------+----------
         1 |       183        105         42 |       330 
         2 |       158        121         49 |       328 
-----------+---------------------------------+----------
     Total |       341        226         91 |       658 

          Pearson chi2(2) =   3.4980   Pr = 0.174
               Cramér's V =   0.0729

. tabchii 183 105 42  \ 158 121 49, a

          observed frequency
          expected frequency
          adjusted residual

-------------------------------------
          |            col           
      row |       1        2        3
----------+--------------------------
        1 |     183      105       42
          | 171.018  113.343   45.638
          |   1.870   -1.370   -0.822
          | 
        2 |     158      121       49
          | 169.982  112.657   45.362
          |  -1.870    1.370    0.822
-------------------------------------

         Pearson chi2(2) =   3.4980   Pr = 0.174
likelihood-ratio chi2(2) =   3.5011   Pr = 0.174

. 
. 
. *     ****************************************************************  *
. *                    Reduced Sample  Hypothesis 3 - Table C3            *
. *     ****************************************************************  *
. tab US if respid < 1105

         US |      Freq.     Percent        Cum.
------------+-----------------------------------
          1 |        158       48.17       48.17
          2 |        121       36.89       85.06
          3 |         49       14.94      100.00
------------+-----------------------------------
      Total |        328      100.00

. tab Trump if respid < 1105

      Trump |      Freq.     Percent        Cum.
------------+-----------------------------------
          1 |        157       48.01       48.01
          2 |        100       30.58       78.59
          3 |         70       21.41      100.00
------------+-----------------------------------
      Total |        327      100.00

. 
. tabi 158 121 49 \\ 157 100 70, chi V

           |               col
       row |         1          2          3 |     Total
-----------+---------------------------------+----------
         1 |       158        121         49 |       328 
         2 |       157        100         70 |       327 
-----------+---------------------------------+----------
     Total |       315        221        119 |       655 

          Pearson chi2(2) =   5.7030   Pr = 0.058
               Cramér's V =   0.0933

. tabchii 158 121 49 \ 157 100 70, a

          observed frequency
          expected frequency
          adjusted residual

-------------------------------------
          |            col           
      row |       1        2        3
----------+--------------------------
        1 |     158      121       49
          | 157.740  110.669   59.591
          |   0.041    1.708   -2.146
          | 
        2 |     157      100       70
          | 157.260  110.331   59.409
          |  -0.041   -1.708    2.146
-------------------------------------

         Pearson chi2(2) =   5.7030   Pr = 0.058
likelihood-ratio chi2(2) =   5.7255   Pr = 0.057

. 
. exit, clear

end of do-file


. exit, clear
